#import <Foundation/Foundation.h>
#import <OpenGLES/ES1/gl.h>

typedef enum {
	kTexturePixelFormat_Auto = 0,
	kTexturePixelFormat_RGBA,
	kTexturePixelFormat_RGB,
	kTexturePixelFormat_Unknow,
} TexturePixelFormat;

@interface Texture2D : NSObject {
	
@private
	GLuint textureID;
	CGSize size;
	NSUInteger width;
	NSUInteger height;
	GLfloat	maxS;
	GLfloat maxT;
    CGSize textureRatio;
    TexturePixelFormat pixelFormat;
}	

@property(nonatomic, readonly) GLuint textureID;
@property(nonatomic, readonly) CGSize size;
@property(nonatomic, readonly) NSUInteger width;
@property(nonatomic, readonly) NSUInteger height;
@property(nonatomic, readonly) GLfloat maxS;
@property(nonatomic, readonly) GLfloat maxT;
@property(nonatomic, readonly) CGSize textureRatio;
@property(nonatomic, readonly) TexturePixelFormat pixelFormat;


- (id) initWithImage:(UIImage*)image filter:(GLenum)filter;


@end

